package cn.kgc.music.common;

import org.junit.Test;

import java.util.Random;

public class RandomNumber {
    public static String random() {
        StringBuilder str=new StringBuilder();//定义变长字符串
                Random random=new Random();
                for (int i=0;i<8;i++){
                    str.append(random.nextInt(10));
                }
                return str.toString();
    }
    public static String randomsix() {
        StringBuilder str=new StringBuilder();//定义变长字符串
        Random random=new Random();
        for (int i=0;i<6;i++){
            str.append(random.nextInt(10));
        }
        return str.toString();
    }
}
